package com.example.shopping.service.imp;

import com.example.shopping.entity.Good;
import com.example.shopping.mapper.GoodsMapper;
import com.example.shopping.service.GoodsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author xuan 2021/9/16
 */
@Service
public class GoodsServiceImpl implements GoodsService {
    @Autowired
    GoodsMapper goodsMapper;

    @Override
    public Good fondGoodByName(String name) {
        return goodsMapper.fondGoodByName(name);
    }
    @Override
    public void insertGood(Integer cid, Double price, String name) {
        goodsMapper.insertGood(cid, price, name);
    }
}
